<template>
    <div class="choiceness">
      <h4>必听书单 <span @click="allbook()">查看全部</span></h4>
      <div class="recommend-content" v-for="i in themeList"  @click="themeclick(i.themeid)">
        <img :src="URL + i.img">
        <div>
          <h6>{{i.title}}</h6>
          <p>{{i.contentabstract}}</p>
          <span>{{i.bookCount}}本书</span>
        </div>
      </div>
    </div>
</template>

<script>
    export default {
        name: "choicenessList",
      props:['themeList'],
      data(){
          return{

          }
      },
      components:{

      },
      mounted(){

      },
      methods:{
        allbook(){
          this.$router.push({name:'necessarily'})
        },
        themeclick(id){
          this.$router.push({name:'singlebook',params:{'id':id}})//调转详情页
        }
      }
    }
</script>

<style scoped>
  .choiceness h4{
    text-align: center;
    font-size: .14rem;
    line-height: .4rem;
  }
  .choiceness h4 span{
    float: right;
    margin-right: .1rem;
    color: #999;
    font-size: .12rem;
  }
  .recommend-content {
    height: .9rem;
    padding: 0 0.08rem;
  }
  .recommend-content img{
    float: left;
    height: 75px;
    width: 75px;
    margin-right: 10px;
  }
  .recommend-content div{
    float: left;
    text-align: left;
    width: calc(100% - 95px);
  }
  .recommend-content div h6{
    font-size: .14rem;
    height: .22rem;
    font-weight: bold;
  }
  .recommend-content div p{
    height: .34rem;
    font-size: .12rem;
    width: 100%;
  }
  .recommend-content div span{
    height: .15rem;
    line-height: .12rem;
    font-size: .12rem;
  }
</style>
